﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Logistics.Manager
{
    public class tc_Permission
    {
        private readonly DataAccess.tc_Permission _permission;
        public tc_Permission()
        {
            _permission = new DataAccess.tc_Permission();
        }
        public bool Add(Model.tc_Permission model)
        {
            return _permission.Add(model);
        }

        public bool Update(Model.tc_Permission model)
        {
            return _permission.Update(model);
        }

        public Model.tc_Permission GetModel(Guid id)
        {
            return _permission.GetModel(id);
        }

        public Model.tc_Permission GetModel(string userId, string name)
        {
            return _permission.GetModel(userId, name);
        }

        public bool Delete(Guid id)
        {
            return _permission.Delete(id);
        }

        public List<Model.tc_Permission> GetList(Guid userId, Model.EPermissionType type)
        {
            return _permission.GetList(userId, type);
        }
    }
}
